<#include "/WEB-INF/fragment/MyTeamHead.ftl">
<body>
     <div class="container">
     <div class="head clearfix">
            <div class="title fl"><a href="${request.contextPath}/index">教学过程控制系统</a></div><div class=""></div>
                <div class="login-fr fr"><#if Session?exists&&Session.userLogin?exists>
        <li class="dropdown">
                 <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">欢迎你， ${Session.userLogin.username!""} <span class="caret"></span></a>
                 <ul class="dropdown-menu">
                   <li><a href="${request.contextPath}/-myTeam">我的团队</a></li>
                   <li role="separator" class="divider"></li>
                   <li><a href="${request.contextPath}/logout">退出登录</a></li>
                 </ul>
               </li>
        </#if></div>
        </div>
        <div>
        <div class="pic" align="center"><img src="http://172.16.1.55/logo.png"></div>
        <div class="team clearfix">
      <div class="create-team fl">我的团队</div>
        </div>
        <div class="underline"></div>
        <table class="table">
            <thead>
                <tr>
                    <th>团队id</th>
                    <th>团队名称</th>
                    <th>团队描述</th>
                    <th>个性域名</th>
                    <th>成员</th>
                    <th>开始时间</th>
                    <th>结束时间</th>
                    <th>团队状态</th>
                    <th>完成度</th>
                </tr>
            </thead>
            <tbody>
              <#if teamList??>
        <#list teamList as team>
                <tr>
                    <td>${team.id!""}</td>
                    <td>${team.name!""}</td>
                    <td>${team.desc!""}</td>
                    <td><a style="color: red;" href="./team?subdomain=<#if team.subdomain??>${team.subdomain}</#if>">${team.subdomain!""}</a></td>
                    <td></td>
                    <td>${team.gmtBegin!""}</td>
                    <td>${team.gmtEnd!""}</td>
                    <td><#if team.status==1>尚未开始</#if>
                    <#if team.status==2>正在实训中</#if>
                    <#if team.status==3>毕业项目实战</#if>
                    <#if team.status==4>完成实训</#if>
                    <#if team.status==5>结束团队</#if></td>
                    <td></td>
                    <td><button class="btn btn-xs btn-danger j_remove_row"><a href="${request.contextPath}/invateMember.action?team.id=${team.id}">邀请成员</a></button></td>
                    <td><button class="btn-xs btn-danger j_copy_row"><a href="${request.contextPath}/team-detaile.action?team.id=${team.id}">修改</a></button></td>
                    <td><button class="btn-xs btn-danger j_copy_row"><a href="">删除</a></button></td>
                </tr>
                </#list>
        </#if> 
                </tbody>
                </table>
        </ul>
        <ul class="pagination pagination-sm ">
        <#if count??>
        <#list 1..count as i>
        <li class="clazz fl">
        <a href="${request.contextPath}/${i}">${i}</a></li>
        </#list>
        </#if>
        </ul>
        </div>
        

       <!--  <script id="table_list" type="text/tms-template">
                     <tr>
                    <td>{{id}}</td>
                    <td>{{name}}</td>
                    <td>{{desc}}</td>
                    <td><a href="">{{subdomain}}</a></td>
                    <td></td>
                    <td>{{gmtBegin}}</td>
                    <td>{{gmtEnd}}</td>
                    <td>{{status}}</td>
                    <td></td>
                    <td><button class="btn btn-xs btn-danger j_remove_row"><a href="${request.contextPath}/-invateMember?team_id={{id}}">邀请成员</a></button></td>
                    <td><button class="btn-xs btn-danger j_copy_row"><a href="${request.contextPath}/-modifiedTeam">修改</a></button></td>
                    </tr>
        </script>
        <script>
            (function(){
        $.getJSON('${request.contextPath}/team_myTeam.action', {}, function(json, textStatus) {
                /*optional stuff to do after success */
                var html=$('#table_list').html();
                for(var i in json){
                    $('.table>tbody').append(parse(html,json[i]));
                }
        });
        function parse(html, data) {
            var str = html;
            for(var i in data) {
                str = str.replace('{{' + i + '}}', data[i]);
            }
            return str;
        }
    }
        )();

        </script> -->
        </body>
</html>
        
String title ,String desc, Long uidManager ,Long uidCreate ,Long uidModified ,Long gmtCreate ,Long gmtModified